﻿<%@ Page Language="C#" AutoEventWireup="true" Inherits="website_admin__root_LeftFrame" Codebehind="LeftFrame.aspx.cs" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
    <title>Untitled Page</title>
    <script type="text/javascript">
        var LOCID_PAGE_LOADING_MSG = "\u6b63\u5728\u52a0\u8f7d...";
        var LOCID_FORM_REQUIRED_BKG_COLOR = "";
        var LOCID_FORM_REQUIRED_ALT = "\u5fc5\u9700";
        var LOCID_COPY_SHORTCUT_ERROR = "\u65e0\u6cd5\u5c06\u6b64\u5feb\u6377\u65b9\u5f0f\u590d\u5236\u5230\u526a\u8d34\u677f\u3002";
        var LOCID_UI_DIR = "LTR";
        var LOCID_AM_DESIGNATOR = "\u4e0a\u5348";
        var LOCID_PM_DESIGNATOR = "\u4e0b\u5348";
        var LOCID_FIRST_WEEK_SELECT = "FirstDay";
        var LOCID_UNRECOGNIZE_DOTC = "\x7b0\x7d \u4e0d\u662f\u53ef\u8bc6\u522b\u7684\u5bf9\u8c61\u7c7b\u578b\u3002";
        var LOCID_XML_PROCESS_ERROR = "\u5904\u7406\u60a8\u7684\u8bf7\u6c42\u65f6\u51fa\u9519\u3002\u8bf7\u7a0d\u5019\u518d\u91cd\u8bd5\u3002";
        var LOCID_POPUP_BLOCKER_ERROR = "Kaigo CRM \u7a97\u53e3\u65e0\u6cd5\u6253\u5f00\uff0c\u53ef\u80fd\u5df2\u88ab\u5f39\u51fa\u7a97\u53e3\u963b\u6b62\u7a0b\u5e8f\u6240\u963b\u6b62\u3002\u8bf7\u5c06\u8fd9\u53f0 Kaigo CRM \u670d\u52a1\u5668\u6dfb\u52a0\u5230\u60a8\u7684\u5f39\u51fa\u7a97\u53e3\u963b\u6b62\u7a0b\u5e8f\u5141\u8bb8\u6253\u5f00\u65b0\u7a97\u53e3\u7684\u7ad9\u70b9\u7684\u5217\u8868\u4e2d\x3a";
        var LOCID_BU_CANNOTDISABLE = "\u5df2\u68c0\u6d4b\u5230\u6b64\u64cd\u4f5c\u5c06\u505c\u7528\u6240\u6709\u5269\u4f59\u7684\u4e1a\u52a1\u90e8\u95e8\uff0c\u56e0\u6b64\u65e0\u6cd5\u7ee7\u7eed\u3002";
        var LOCID_DIALOG_OFFSET_WIDTH = "0";
        var LOCID_DIALOG_OFFSET_HEIGHT = "0";
        var LOCID_ERROR_DIALOG_WIDTH = "550";
        var LOCID_ERROR_DIALOG_HEIGHT = "260";
        var LOCID_CONTRACTS_TDIALOG_WIDTH = "350";
        var LOCID_CONTRACTS_TDIALOG_HEIGHT = "350";
        var LOCID_ARRAY_SHORT_MONTHS = "1 \u6708,2 \u6708,3 \u6708,4 \u6708,5 \u6708,6 \u6708,7 \u6708,8 \u6708,9 \u6708,10 \u6708,11 \u6708,12 \u6708";
        var LOCID_ARRAY_LONG_MONTHS = "\u4e00\u6708,\u4e8c\u6708,\u4e09\u6708,\u56db\u6708,\u4e94\u6708,\u516d\u6708,\u4e03\u6708,\u516b\u6708,\u4e5d\u6708,\u5341\u6708,\u5341\u4e00\u6708,\u5341\u4e8c\u6708,";
        var LOCID_ARRAY_SHORT_DAYS = "\u65e5,\u4e00,\u4e8c,\u4e09,\u56db,\u4e94,\u516d";
        var LOCID_ARRAY_SHORTEST_DAYS = "\u65e5,\u4e00,\u4e8c,\u4e09,\u56db,\u4e94,\u516d";
        var LOCID_ARRAY_LONG_DAYS = "\u661f\u671f\u65e5,\u661f\u671f\u4e00,\u661f\u671f\u4e8c,\u661f\u671f\u4e09,\u661f\u671f\u56db,\u661f\u671f\u4e94,\u661f\u671f\u516d";
        var LOCID_SHOW_WEEK_CAL_WIDTH = "170";
        var LOCID_NO_WEEK_CAL_WIDTH = "150";
        var LOCID_CALENDAR_HEIGHT = "163";
        var LOCID_TODAY_DATE_FORMAT_MASK = "\u4eca\u5929\x3a\x7b0\x7d";
        var LOCID_ALERT_ENTER_VALID_DATE = "\u6307\u5b9a\u7684\u65e5\u671f\u683c\u5f0f\u65e0\u6548\u6216\u65e5\u671f\u8d85\u51fa\u4e86\u6709\u6548\u8303\u56f4\u3002\u8bf7\u6309\u4ee5\u4e0b\u683c\u5f0f\u8f93\u5165\u6709\u6548\u7684\u65e5\u671f\x3a \x7b0\x7d";
        var LOCID_ALERT_CALDATE_FAIL = "\u83b7\u53d6\u65e5\u671f\u65f6\u51fa\u9519";
        var LOCID_ALERT_ACTUAL_DATE_FAIL = "\u83b7\u53d6\u65e5\u671f\u65f6\u51fa\u9519";
        var LOCID_YEAR_DISPLAYFORMAT = "\x7b0\x7d\x7b1\x7d \u5e74";
        var LOCID_SINGULAR_MINUTE = "\u5206\u949f";
        var LOCID_PLURAL_MINUTE = "\u5206\u949f";
        var LOCID_SINGULAR_HOUR = "\u5c0f\u65f6";
        var LOCID_PLURAL_HOUR = "\u5c0f\u65f6";
        var LOCID_SINGULAR_DAY = "\u5929";
        var LOCID_PLURAL_DAY = "\u5929";
        var LOCID_VALID_DURATION = "\u5fc5\u987b\u8f93\u5165\u6709\u6548\u7684\u6301\u7eed\u65f6\u95f4\u3002";
        var LOCID_ERROR_SAVE_DURATION = "Kaigo CRM \u65e0\u6cd5\u4fdd\u5b58\u5bf9\u6301\u7eed\u65f6\u95f4\u7684\u66f4\u6539\u3002\u8bf7\u91cd\u8bd5\u66f4\u6539\u6301\u7eed\u65f6\u95f4\u7684\u503c\u3002";
        var LOCID_1_MINUTE = "1 \u5206\u949f";
        var LOCID_5_MINUTES = "5 \u5206\u949f";
        var LOCID_15_MINUTES = "15 \u5206\u949f";
        var LOCID_30_MINUTES = "30 \u5206\u949f";
        var LOCID_45_MINUTES = "45 \u5206\u949f";
        var LOCID_1_HOUR = "1 \u5c0f\u65f6";
        var LOCID_1_5_HOURS = "1.5 \u5c0f\u65f6";
        var LOCID_2_HOURS = "2 \u5c0f\u65f6";
        var LOCID_2_5_HOURS = "2.5 \u5c0f\u65f6";
        var LOCID_3_HOURS = "3 \u5c0f\u65f6";
        var LOCID_3_5_HOURS = "3.5 \u5c0f\u65f6";
        var LOCID_4_HOURS = "4 \u5c0f\u65f6";
        var LOCID_4_5_HOURS = "4.5 \u5c0f\u65f6";
        var LOCID_5_HOURS = "5 \u5c0f\u65f6";
        var LOCID_5_5_HOURS = "5.5 \u5c0f\u65f6";
        var LOCID_6_HOURS = "6 \u5c0f\u65f6";
        var LOCID_6_5_HOURS = "6.5 \u5c0f\u65f6";
        var LOCID_7_HOURS = "7 \u5c0f\u65f6";
        var LOCID_7_5_HOURS = "7.5 \u5c0f\u65f6";
        var LOCID_8_HOURS = "8 \u5c0f\u65f6";
        var LOCID_1_DAY = "1 \u5929";
        var LOCID_2_DAYS = "2 \u5929";
        var LOCID_3_DAYS = "3 \u5929";
        var LOCID_DURATION_BADTYPE = "\u6b64\u63a7\u4ef6\u53ea\u63a5\u53d7\u4ecb\u4e8e \x7b0\x7d \u548c \x7b1\x7d \u4e4b\u95f4\u7684\u6574\u6570\u6216\u8005\u53ea\u80fd\u8f93\u5165\u7a7a\u3002";
        var LOCID_DURATION_NOSAVE = "Kaigo CRM \u65e0\u6cd5\u4fdd\u5b58\u5bf9\u6301\u7eed\u65f6\u95f4\u7684\u66f4\u6539\u3002\u8bf7\u91cd\u8bd5\u66f4\u6539\u6301\u7eed\u65f6\u95f4\u7684\u503c\u3002";
        var LOCID_ONE_MINUTE_MASK = "\x7b0\x7d \u5206\u949f";
        var LOCID_N_MINUTES_MASK = "\x7b0\x7d \u5206\u949f";
        var LOCID_1_HOUR_MASK = "\x7b0\x7d \u5c0f\u65f6";
        var LOCID_N_HOURS_MASK = "\x7b0\x7d \u5c0f\u65f6";
        var LOCID_1_DAY_MASK = "\x7b0\x7d \u5929";
        var LOCID_N_DAYS_MASK = "\x7b0\x7d \u5929";
        var LOCID_DTM_BLANK_DATE_ERROR = "\u5fc5\u987b\u63d0\u4f9b\u65e5\u671f\u3002";
        var LOCID_DTM_BLANK_TIME_ERROR = "\u8bf7\u8f93\u5165\u6709\u6548\u7684\u65f6\u95f4\u3002";
        var LOCID_TIME_SEPARATOR = "\x3a";
        var LOCID_FORMS_SAVE_CONFIRM_TITLE = "\u5c1a\u672a\u4fdd\u5b58\u6240\u505a\u7684\u66f4\u6539\u3002\u8981\u505c\u7559\u5728\u8be5\u9875\u9762\u4e0a\uff0c\u4ee5\u4fbf\u4fdd\u5b58\u6240\u505a\u7684\u66f4\u6539\uff0c\u8bf7\u5355\u51fb\u201c\u53d6\u6d88\u201d\u3002";
        var LOCID_FORM_PROIVE_VALUE_MASK = "\u5fc5\u987b\u63d0\u4f9b\x7b0\x7d\u7684\u503c\u3002";
        var LOCID_FORM_PRINT_DIRTY_MESSAGE = "\u6b64\u8868\u5355\u5df2\u66f4\u6539\uff0c\u6253\u5370\u4e4b\u524d\u5fc5\u987b\u8fdb\u884c\u4fdd\u5b58\u3002";
        var LOCID_ENTER_VALID_NUMBER = "\u5fc5\u987b\u8f93\u5165\u6709\u6548\u7684\u6570\u5b57\u3002";
        var LOCID_REMOTECOMMAND_ERROR = "\u53d1\u751f\u4e86\u9519\u8bef\u3002\u8bf7\u91cd\u8bd5\u6b64\u64cd\u4f5c\u3002\u5982\u679c\u95ee\u9898\u4ecd\u7136\u5b58\u5728\uff0c\u8bf7\u8bbf\u95ee Kaigo CRM \u793e\u533a\u4ee5\u83b7\u53d6\u89e3\u51b3\u65b9\u6848\u6216\u8005\u4e0e\u60a8\u6240\u5728\u7ec4\u7ec7\u7684 Kaigo CRM \u7ba1\u7406\u5458\u8054\u7cfb\u3002\u6700\u540e\uff0c\u60a8\u53ef\u4ee5\u4e0e Microsoft \u652f\u6301\u8054\u7cfb\u3002";

        var WEB_APP_URL = "";
        var HELP_SKU = "OP";
        var IS_LIVE = false;
        var IS_PATHBASEDURLS = true;
        var ORG_UNIQUE_NAME = "webs\website_admin";
        var _ErrorCodesIsvAborted = "0x80040265";
        var ScriptErrorReportingPreference = 1;
        var ScriptErrorStatusBar = "\u7f51\u9875\u4e0a\u6709\u9519\u8bef\u3002";
        var _bPresenceEnabled = true;
        var ORG_DATE_FORMATSTRING = "yyyy/M/d";
        var ORG_IS_GREGORIANCALENDAR = false;
        var ORG_DATE_SEPARATOR = "-";
        var ORG_DATE_START_DAY = 0;
        var ORG_LANGUAGE_CODE = 2052;
        var ORG_NUMBER_FORMAT_MASK = "\x23,\x23\x230.\x2a\x3b\x7e\x23,\x23\x230.\x2a";
        var ORG_TIME_FORMAT = 0;
        var ORG_SHOW_WEEK_NUMBER = false;
        var ORG_NUMBER_DECIMAL_SEPARATOR = ".";
        var ORG_NUMBER_GROUP_SEPARATOR = ",";
        var AUTHENTICATION_TYPE = 0;
        var ORG_TIMEZONE_OFFSET = 480;
        var USER_DATE_FORMATSTRING = "yyyy/M/d";
        var USER_IS_GREGORIANCALENDAR = true;
        var USER_DATE_SEPARATOR = "-";
        var USER_DATE_FORMATTED_FORMATSTRING = "yyyy/M/d";
        var DEFAULT_USER_NUMBER_FORMAT_MASK = "\x23,\x23\x230.\x2a\x3b\x7e\x23,\x23\x230.\x2a";
        var USER_LANGUAGE_CODE = 2052;
        var USER_HELP_LCID = "2052";
        var USER_NUMBER_FORMAT_MASK = "\x23,\x23\x230.\x2a\x3b\x7e\x23,\x23\x230.\x2a";
        var USER_TIME_FORMAT = "H:mm";
        var USER_SHOW_WEEK_NUMBER = false;
        var USER_NUMBER_DECIMAL_SEPARATOR = ".";
        var USER_NUMBER_GROUP_SEPARATOR = ",";
        var HELP_SERVER_URL = "";
    </script>

    <script type="text/javascript" src="../_static/_common/scripts/encodedecode.js"></script>

    <script type="text/javascript" src="../_static/_controls/util/util.js"></script>

    <script type="text/javascript" src="../_static/_common/scripts/global.js"></script>

    <script type="text/javascript" src="../_static/_common/scripts/xmlutil.js"></script>

    <script type="text/javascript" src="../_static/_controls/remotecommands/remotecommand.js"></script> 

    <script type="text/javascript" src="../_static/_controls/datetime/date.js"></script>

    <script type="text/javascript" src="../_static/_common/scripts/presence.js"></script>

    <script type="text/javascript" src="../_static/_controls/number/number.js"></script>

    <link rel="stylesheet" type="text/css" href="../_common/styles/global.css" />
    <link rel="stylesheet" type="text/css" href="../_common/styles/global-styles.css" />
    <link rel="stylesheet" type="text/css" href="../_common/styles/global-dynamic-styles.css" />
    <link rel="stylesheet" type="text/css" href="../_common/styles/fonts.css" />
    <link rel="stylesheet" type="text/css" href="../_common/styles/left.css" />
    <link rel="stylesheet" type="text/css" href="../_common/styles/minical.css" />
    <link rel="stylesheet" type="text/css" href="../_forms/controls/controls.css" />
    <link rel="stylesheet" type="text/css" href="../_nav/nav.css" />
    
    <style type="text/css">
    body
    {
        margin: 0px;
        background: transparent;
        overflow: hidden;
        background: url("../_common/Skin/default/images/leftbg.gif");
    }
    </style>
     
    <script type="text/javascript" language="javascript">
    <!--
        function LoadIFrame() {
            var url = "workplace.aspx?catalogid=" + parent.topFrame.CurrentMenuId;
            WorkplaceFrame.document.body.innerHTML = "<table class='stdTable' width='100%' height='100%'><tr><td style='vertical-align: middle' align='center'><IMG alt='' src='../_imgs/AdvFind/progress.gif'><br>Loading menu ...</td></tr></table>";
            document.getElementById("WorkplaceFrame").src = url;
        }
        function getNavBarFrame(sAreaId) {
            return window.frames(sAreaId + "Frame");
        }

        function getNavBarDiv(sAreaId) {
            return document.all(sAreaId + "Div")
        }
        function loadArea(sAreaId) {
            if (loadLeftNavBar(sAreaId)) {
                loadHomePage(sAreaId);
            }
            else {
                var oSubArea = getNavBarFrame(sAreaId).crmNavBar.SelectedItem;
                if (!IsNull(oSubArea)) {
                    loadHomePage(sAreaId, getNavBarFrame(sAreaId).crmNavBar.SelectedArea.id, oSubArea.id);
                }
            }
        }

        function loadLeftNavBar(sAreaId, sGroupId, sSubAreaId) {
            var oAreaNode = siteMap.selectSingleNode("/SiteMap/Area[@Id='" + sAreaId + "']");

            if (!IsNull(oAreaNode)) {
                top.setAreaTitle(oAreaNode.getAttribute("Title"));
            }

            var o = getNavBarDiv(sAreaId);
            if (o) {
                o.style.display = "inline";
                if (sGroupId && sSubAreaId) {
                    getNavBarFrame(sAreaId).crmNavBar.SelectItem(sGroupId, sSubAreaId);
                }

                return false;
            }
            else {
                var sUrl = prependOrgName("/_root/" + sAreaId + ".aspx");

                html = "<iframe src='" + sUrl;

                html += "' id='" + sAreaId + "Frame' scrolling='no' width='100%' height='100%' frameborder='0'></iframe>";

                o = document.createElement("DIV");
                o.id = sAreaId + "Div";
                o.innerHTML = html;

                tdAreas.appendChild(o);

                return true;
            }
        }

        function loadHomePage(sAreaId, sGroupId, sSubAreaId) {
            sAreaId = "Workplace";

            var sGroupExp;
            var sSubAreaExp = IsNull(sSubAreaId) ? "[0]" : "[@Id='" + sSubAreaId + "']";

            if (IsNull(sAreaId)) {
                sAreaId = crmWonderBar.SelectedItem.id;
            }

            if (IsNull(sGroupId) && IsNull(sSubAreaId)) {
                sGroupExp = "[0]";
            }
            else if (IsNull(sGroupId) && !IsNull(sSubAreaId)) {
                sGroupExp = "";
            }
            else {
                sGroupExp = "[@Id='" + sGroupId + "']";
            }

            var oNode;
            if (sSubAreaId == "-1") {
                oNode = siteMap.selectSingleNode("/SiteMap/Area[@Id='" + sAreaId + "']/Group" + sGroupExp);
            }
            else {
                oNode = siteMap.selectSingleNode("/SiteMap/Area[@Id='" + sAreaId + "']/Group" + sGroupExp + "/SubArea" + sSubAreaExp);
            }
            if (!IsNull(oNode)) {
                try {
                    top.stage.document.body.innerHTML = "<table class='stdTable' style='background-color:FFFFFF'><tr><td style='vertical-align: middle' align='center'><IMG alt='' src='../_imgs/AdvFind/progress.gif'><br>" + CrmEncodeDecode.CrmHtmlEncode(LOCID_PAGE_LOADING_MSG) + "</td></tr></table>";
                }
                catch (e) {

                }
                var sUrl = onUrlLoaded(oNode.getAttribute("Id"), oNode.getAttribute("Url"));

                if (oNode.getAttribute("PassParams") == "1" || oNode.getAttribute("PassParams") == "true") {
                    sUrl += sUrl.indexOf("?") < 0 ? "?" : "&";
                    sUrl += "orgname=" + CrmEncodeDecode.CrmUrlEncode(ORG_UNIQUE_NAME);
                    sUrl += "&userlcid=" + CrmEncodeDecode.CrmUrlEncode(USER_LANGUAGE_CODE);
                    sUrl += "&orglcid=" + CrmEncodeDecode.CrmUrlEncode(ORG_LANGUAGE_CODE);
                }
                top.frmright.location.href = CrmEncodeDecode.CrmXmlEncode(sUrl);
                //top.setStageTitle(oNode.getAttribute("Title"));
            }
        }

        function onUrlLoaded(sPageId, sUrl) {
            switch (sPageId) {
                case "nav_apptbook":
                    return sUrl + getApptBookParameters();
                    break;
                default:
                    return sUrl;
            }
        }

        function getApptBookParameters() {
            var defaultTime = LocalDateTimeNow();
            defaultTime.setHours(0, 0, 0, 0);

            var dStartDate = new Date(GetCachedSetting("AB_StartDate", defaultTime));
            var dEndDate = new Date(GetCachedSetting("AB_EndDate", defaultTime));
            var iZoomLevel = GetCachedSetting("AB_ZoomLevel", 4);
            var bShowConflict = GetCachedSetting("AB_ShowConflict", false);

            return "?zoomLevel=" + iZoomLevel + "&startDate=" + FormatUtcDate(dStartDate) + "&endDate=" + FormatUtcDate(dEndDate) + "&showConflict=" + bShowConflict;
        }

        function goTo(sAreaId, sGroupId, sSubAreaId) {
            hideCurrentNavBar();
            if (!IsNull(crmWonderBar.SelectItem(sAreaId))) {
                loadLeftNavBar(sAreaId, sGroupId, sSubAreaId);
            }
        }

        function hideCurrentNavBar() {
            if (!IsNull(crmWonderBar.SelectedItem)) {
                var o = getNavBarDiv(crmWonderBar.SelectedItem.id);
                if (!IsNull(o)) {
                    o.style.display = "none";
                }
            }
        }
    //-->
    </script>
</head>
<body onload="LoadIFrame();">
    <xml id="siteMap">
        <SiteMap>
            <Area Id="Workplace" ShowGroups="True" Title="" Icon="../_imgs/workplace_24x24.gif">
                <asp:Repeater ID="rptPersonalCatalog" runat="server" OnItemDataBound="rptPersonalCatalog_ItemDataBound">
                    <ItemTemplate>
                       <Group Id="<%# Eval("CatalogNumCode") %>" Title="<%# Common.Utils.HtmlEncode(Eval("CatalogName").ToString()) %>" Url="<%# Eval("PageUrl") %>" >
                            <asp:Repeater ID="rptPersonalCatalogItem" runat="server">
                                <ItemTemplate>
                                    <SubArea Id="<%# Eval("CatalogNumCode") %>" Url="<%# Eval("PageUrl") %>" PassParams="0" Title="<%# Common.Utils.HtmlEncode(Eval("CatalogName").ToString()) %>" Icon="../_imgs/nav_dubarea_icon.gif" />
                                </ItemTemplate>
                            </asp:Repeater>
                         </Group>
                    </ItemTemplate>
                </asp:Repeater>
            </Area>
        </SiteMap>
    </xml>
    <form id="form1" runat="server">
     <table class="stdTable" cellpadding="0" cellspacing="0">
        <tr height="100%" class="ms-crm-Form-Background">
            <td id="tdAreas" valign="top" class="ms-crm-Nav-Groups">
                <div id="WorkplaceDiv">
                    <iframe scrolling="no" width="100%" height="100%" frameborder="0" id="WorkplaceFrame"></iframe>
                </div>
            </td>
        </tr>
    </table>
    </form>
</body>
</html>
